import {
    HTTP
} from "../utils/http.js"
class AccountModel extends HTTP {
    //  获取验证码
    mobileVerfiCode(mobilePhone) {
        return this.request({
            url: 'bj/bjShellAntMiniProgramService/getValidCode',
            data: {
                mobilePhone
            },
            method: 'POST'
        })
    }
    //  注册
    registered(mobilePhone,validCode) {
        return this.request({
            url: 'bj/bjShellAntMiniProgramService/registered',
            data: {
                mobilePhone,
                validCode,
            },
            method: 'POST'
        })
    }
    //  登录
    loginMember(mobilePhone,validCode) {
        return this.request({
            url: 'bj/bjShellAntMiniProgramService/loginMember',
            data: {
                mobilePhone,
                validCode,
            },
            method: 'POST'
        })
    }
    //  修改手机号
    updateMemberPhone(mobilePhone,newMobilePhone,validCode,idno) {
        return this.request({
            url: 'program/antProgramApiService/updateMemberPhone',
            data: {
                mobilePhone,
                newMobilePhone,
                validCode,
                idno
            },
            method: 'POST'
        })
    }
    //  忘记密码
    resetPayPin(cardPin,validCode,idno) {
        return this.request({
            url: 'bj/bjShellAntMiniProgramService/resetPwd',
            data: {
                cardPin,
                validCode,
                idno
            },
            method: 'POST'
        })
    }
    //  设置支付初始密码接口
    setPayPwd(cardPin,idno) {
        return this.request({
            url: 'bj/bjShellAntMiniProgramService/activityMember',
            data: {
                cardPin,
                idno
            },
            method: 'POST'
        })
    }
    //  修改支付密码接口
    modifyPwd(cardPin,newCardPin) {
        return this.request({
            url: 'bj/bjShellAntMiniProgramService/modifyPwd',
            data: {
                cardPin,
                newCardPin
            },
            method: 'POST'
        })
    }
    getCouponListByOrderIdOrOpenId(couponType,orderId) {
        return this.request({
            url: 'bj/bjShellAntMiniProgramService/getCouponListByOrderIdOrOpenId',
            data: {
                couponType,
                orderId
            },
            method: 'POST'
        })
    }
}
export {
    AccountModel
}